#ifndef _AV_FORMAT_H_
#define _AV_FORMAT_H_
#include "inttypes.h"

typedef struct AVOutputParam {
    char *name;
    char *long_name;
    char *mime_type;
    char *extensions; /* comma separated extensions */
    /* size of private data so that it can be allocated in the wrapper */
    int priv_data_size;
	char* priv_data;
    /* output support */
    unsigned int audio_codec; /* default audio codec */
    unsigned int video_codec; /* default video codec */

	
    int sample_rate;
	int samplewidth;
    int channels;
    int width;
    int height;
    unsigned int pix_fmt;
    int channel; /* used to select dv channel */
   
	//Audio Buffer
	int AudioBufferSize;
	int AudioBufferMaxCounter;
	int AudioBufferTime;

	//VideoBuffer
	int VideoBufferSize;
	int VideoBufferMaxCounter;
	int VideoBufferTime;
     
	AVStream* stream;
} AVOutputParam;


typedef struct AVOutputStatus
{
	/* stream info */
    int64_t timestamp;

	  /* decoding: position of the first frame of the component, in
       AV_TIME_BASE fractional seconds. NEVER set this value directly:
       it is deduced from the AVStream values.  */
    int64_t start_time;
    /* decoding: duration of the stream, in AV_TIME_BASE fractional
       seconds. NEVER set this value directly: it is deduced from the
       AVStream values.  */
    int64_t duration;
   
    /* decoding: total stream bitrate in bit/s, 0 if not
       available. Never set it directly if the file_size and the
       duration are known as ffmpeg can compute it automatically. */
    int bit_rate;

      
    int deley;
    int max_delay;

	//Audio Buffer
	int AudioBufferSize;
	int AudioBufferMaxCounter;
	int AudioBufferTime;

}AVOutputStatus;
#endif